From 8ebf6ba2ca6000b99d6049ebbe2726c92af0e4e9 Mon Sep 17 00:00:00 2001 From: Alessandro Bono Date: Fri, 20 Feb 2026 23:56:17 +0100 Subject: [PATCH] lookingGlass: Use replaceAll() Remove all the newlines occurrences, not just the first one. Fixes: 52ae75d4b ("LookingGlass - JavaScript prompt and interactive Clutter controller") Part-of: --- js/ui/lookingGlass.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/ui/lookingGlass.js b/js/ui/lookingGlass.js index 41f4940f5..7ba30eb95 100644 --- a/js/ui/lookingGlass.js +++ b/js/ui/lookingGlass.js @@ -1446,7 +1446,7 @@ class LookingGlass extends St.BoxLayout { let text = o.get_text(); // Ensure we don't get newlines in the command; the history file is // newline-separated. - text = text.replace('\n', ' '); + text = text.replaceAll('\n', ' '); this._evaluate(text).catch(logError); return true; }); -- 2.39.5